/*******************************************************************
* ++
* Author        :	ThienTN
* Description   :	Employee.h in project HumanResource
* 
* Mod. History  :	28/07/2012 - ThienTN
*
* --
*******************************************************************/

#ifndef EMPLOYEE_H
#define EMPLOYEE_H

#include "Utility.h"

/*
 * Abstract class
 */
class CEmployee
{
protected:
	/*
	 * Property of program
	 */	
	string m_wszID;
	string m_wszName;
	Date m_birthDay;
	string m_wszGradSchool;
	int m_nGradYear;
	int m_nGradType;
public:
	
	/*
	 * declare operator < to compare 2 Employee
	 */
	bool operator<( const CEmployee &a)
	{
		return m_nGradYear < a.m_nGradYear;
	}
	/*
	 * Prototype of program
	 */
	void Swap(CEmployee &pEmployee1, CEmployee &pEmployee2);
	void InputEmployee(CEmployee *pEmployee);
	void OutputEmployee(vector <CEmployee> pList);
	void SearchEmployee(vector <CEmployee> pList);
	void SortYear(vector <CEmployee> &pList);
	void Addtail(vector <CEmployee>  &pList, CEmployee *pEmployee);
	void RemoveEmployee(vector <CEmployee> &pList);
	void AutoInputEmployee(vector<CEmployee> &list);
	friend bool CheckBirthday(CEmployee *pEmployee);

	// constructor
	CEmployee(void);
	// destructor
	~CEmployee(void);
};

#endif